<?php
// +----------------------------------------------------------------------
// | ThinkCMF [ WE CAN DO IT MORE SIMPLE ]
// +----------------------------------------------------------------------
// | Copyright (c) 2013-2018 http://www.thinkcmf.com All rights reserved.
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: 老猫 <zxxjjforever@163.com>
// +----------------------------------------------------------------------
namespace app\blog\controller;
use cmf\controller\AdminBaseController;
use app\blog\model\CashierModel as CA;
use think\Db;
class CashierController extends AdminBaseController
{
    public function index()
    {

    }
    /*
     * 列表信息
     * */
    public function cashier()
    {
        $db=new CA;
        $shop=$db->shop();
        $array=input('request.');
        $where=array();
        if(!empty($array['operator']))
        {
            $where['operator']=$array['operator'];
        }
        if(!empty($array['storeid']))
        {
            $where['storeid']=$array['storeid'];
        }
        if(!empty($array['start_time'])&& !empty($array['end_time']))
        {
            $start=strtotime($array['start_time']);
            $end=strtotime($array['end_time']);
            $where['utime']=array('between',"$start,$end");
        }
        $data=$db->index($where);
        $data->appends($where);
        $this->assign('data',$data);
        $this->assign('shop',$shop);
        $this->assign('page',$data->render());
        return $this->fetch('cashier/index');
    }

}
























